import store from "@/store";
import dayjs from "dayjs";
export const formItemStyle = {
  paddingLeft: "20px",
};

export const cellStyle = {
  background: "rgba(28, 155, 252, 0.02)",
  color: "rgb(142, 155, 185)",
  textAlign: "center",
};

// 表头单元格样式
export const headerCellStyle = {
  background: "rgba(28, 155, 252, 0.02)",
  color: "rgb(142, 155, 185)",
  textAlign: "center",
};
// 表格内表单子样式
export const tableFormStyle = {
  marginBottom: 0,
};
export const formBase = [
  {
    label: "库位属性",
    type: "select",
    field: "attributes",
    optionsKey: "label",
    optionsValue: "label",
    options: [{ label: "L" }, { label: "M" }, { label: "S" }],
  },
  {
    label: "第一次分拣口",
    type: "input",
    field: "firstSorting",
  },
  {
    label: "第二次分拣口",
    type: "input",
    field: "secondSorting",
  },
  {
    label: "库位编号",
    type: "input",
    field: "locationName",
  },
  {
    label: "所属区域",
    type: "input",
    field: "region",
  },
  {
    label: "仓库",
    type: "select",
    field: "warehouseId",
    optionsKey: "warehouseName",
    optionsValue: "id",
    options: store.state.custom_dict.warehouse,
  },
];
console.log(store.state.custom_dict.warehouse, 3);
export const tableBase = [
  {
    label: "仓库名称",
    prop: "warehouseName",
    width: 200,
    operate: {
      type: "select",
      field: "warehouseId",
      optionsKey: "warehouseName",
      optionsValue: "id",
      options: store.state.custom_dict.warehouse,
    },
  },
  {
    label: "所属区域",
    prop: "region",
    width: 200,
    operate: {
      type: "input",
      field: "region",
    },
  },
  {
    label: "首次分拣口",
    prop: "firstSorting",
    width: 200,
    operate: {
      type: "input",
      field: "firstSorting",
    },
  },
  {
    label: "二次分拣口",
    prop: "secondSorting",
    width: 200,
    operate: {
      type: "input",
      field: "secondSorting",
    },
  },
  {
    label: "库位名",
    prop: "locationName",
    width: 200,
    operate: {
      type: "input",
      field: "locationName",
    },
  },
  {
    label: "属性",
    prop: "attributes",
    width: 200,
    operate: {
      type: "select",
      field: "attributes",
      optionsKey: "label",
      optionsValue: "label",
      options: [{ label: "L" }, { label: "M" }, { label: "S" }],
    },
  },
  {
    label: "备注说明",
    prop: "remarks",
    width: 200,
    operate: {
      type: "input",
      field: "remarks",
    },
  },
];
